package com.ruoyi.technology.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.technology.mapper.TechnologyDesignMapper;
import com.ruoyi.technology.domain.TechnologyDesign;
import com.ruoyi.technology.service.ITechnologyDesignService;
import com.ruoyi.common.core.text.Convert;

/**
 * 工艺设计Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-01-13
 */
@Service
public class TechnologyDesignServiceImpl implements ITechnologyDesignService 
{
    @Autowired
    private TechnologyDesignMapper technologyDesignMapper;

    /**
     * 查询工艺设计
     * 
     * @param id 工艺设计主键
     * @return 工艺设计
     */
    @Override
    public TechnologyDesign selectTechnologyDesignById(Long id)
    {
        return technologyDesignMapper.selectTechnologyDesignById(id);
    }

    /**
     * 查询工艺设计列表
     * 
     * @param technologyDesign 工艺设计
     * @return 工艺设计
     */
    @Override
    public List<TechnologyDesign> selectTechnologyDesignList(TechnologyDesign technologyDesign)
    {
        return technologyDesignMapper.selectTechnologyDesignList(technologyDesign);
    }

    /**
     * 新增工艺设计
     * 
     * @param technologyDesign 工艺设计
     * @return 结果
     */
    @Override
    public int insertTechnologyDesign(TechnologyDesign technologyDesign)
    {
        return technologyDesignMapper.insertTechnologyDesign(technologyDesign);
    }

    /**
     * 修改工艺设计
     * 
     * @param technologyDesign 工艺设计
     * @return 结果
     */
    @Override
    public int updateTechnologyDesign(TechnologyDesign technologyDesign)
    {
        return technologyDesignMapper.updateTechnologyDesign(technologyDesign);
    }

    /**
     * 批量删除工艺设计
     * 
     * @param ids 需要删除的工艺设计主键
     * @return 结果
     */
    @Override
    public int deleteTechnologyDesignByIds(String ids)
    {
        return technologyDesignMapper.deleteTechnologyDesignByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除工艺设计信息
     * 
     * @param id 工艺设计主键
     * @return 结果
     */
    @Override
    public int deleteTechnologyDesignById(Long id)
    {
        return technologyDesignMapper.deleteTechnologyDesignById(id);
    }
}
